const seq = require('sequelize');
const db = require('../config/database');
const Model = db.defineModel('xs_readhistory', {
	userid: {
		type: seq.STRING(20),
		allowNull: true,
		comment: '用户ID',
		unique: true
	},
	bookid: {
		type: seq.STRING(50),
		comment: '小说ID',
		unique: true
	},
	currchapter: {
		type: seq.STRING(50),
		allowNull: true,
		comment: '当前章节'
	},
	createtime: {
		type: seq.BIGINT(13),
		comment: '加入时间'
	},
	updatetime: {
		type: seq.BIGINT(13),
		comment: '阅读时间'
	}
});
module.exports = Model;